]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
keyboard: Rename function
authorCarlos Garnacho <carlosg@gnome.org>
Fri, 26 Jan 2024 15:19:58 +0000 (16:19 +0100)
committerCarlos Garnacho <carlosg@gnome.org>
Thu, 29 Feb 2024 15:34:21 +0000 (16:34 +0100)
Avoid the "ForGroup" suffix, and get the keyboard group implicitly.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3162>

js/ui/keyboard.js

index 05ac18a8b46899bde36f2c8dadefb0cb2b2a2672..0c68a5971dd4846da73aca77e105d7aa4c48f44a 100644 (file)
@@ -1486,7 +1486,8 @@ export const Keyboard = GObject.registerClass({
         return layers;
     }
 
-    _ensureKeysForGroup(group) {
+    _ensureKeys() {
+        const group = this._keyboardController.getCurrentGroup();
         if (!this._groups[group])
             this._groups[group] = this._createLayersForGroup(group);
     }
@@ -1788,7 +1789,7 @@ export const Keyboard = GObject.registerClass({
     }
 
     _updateKeys() {
-        this._ensureKeysForGroup(this._keyboardController.getCurrentGroup());
+        this._ensureKeys();
         this._setActiveLayer(0);
     }